import * as Mock from 'mockjs';

module.exports = {
  '/api/getRepos': {
    dataSource: [
      {
        id: 1,
        name: 'facebook/react',
        description: 'A declarative, efficient, and flexible JavaScript library for building user interfaces',
        logo: 'https://avatars3.githubusercontent.com/u/69631',
      },
      {
        id: 2,
        name: 'vuejs/vue',
        description: 'Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web. ',
        logo: 'https://avatars1.githubusercontent.com/u/6128107',
      },
      {
        id: 3,
        name: 'angular/angular',
        description: 'One framework. Mobile & desktop. ',
        logo: 'https://avatars3.githubusercontent.com/u/139426',
      },
      {
        id: 4,
        name: 'nuxt/nuxt.js',
        description: 'The Vue.js Framework',
        logo: 'https://avatars2.githubusercontent.com/u/23360933',
      },
      {
        id: 5,
        name: 'zeit/next.js',
        description: 'The React Framework',
        logo: 'https://avatars0.githubusercontent.com/u/14985020',
      },
      {
        id: 6,
        name: 'ice-lab/ice.js',
        description: 'A universal framework based on React.js.',
        logo: 'https://avatars1.githubusercontent.com/u/1961952',
      },
    ],
  },
  '/api/dataDef/USER': {
    "code": 1,
    "msg": "success",
    "data": {
      "code": "USER",
      "name": "用户管理",
      "type": "0",
      "acode": "base",
      "auditFlag": "0",
      "version": 0,
      "fieldList": [
        {
          "code": "C01",
          "name": "用户ID",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "00",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000001",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C02",
          "name": "部门ID",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "01",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000002",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C03",
          "name": "用户账号",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "02",
          "version": 0,
          "maxLimit": 50,
          "minLimit": 5,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000003",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C04",
          "name": "用户昵称",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "03",
          "version": 0,
          "maxLimit": 10,
          "minLimit": 5,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000004",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C05",
          "name": "用户类型",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "04",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000005",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C06",
          "name": "用户邮箱",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "05",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000006",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C07",
          "name": "手机号码",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "06",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000007",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C08",
          "name": "用户性别",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "07",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000008",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C09",
          "name": "头像地址",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "08",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000009",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C10",
          "name": "密码",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "09",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000010",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C11",
          "name": "帐号状态",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "07",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000011",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C12",
          "name": "删除标志",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "08",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000012",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C13",
          "name": "最后登录IP",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "09",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000013",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C14",
          "name": "最后登录时间",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "06",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000014",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C15",
          "name": "创建者",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "00",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000015",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C16",
          "name": "创建时间",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "00",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000016",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C17",
          "name": "更新者",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "00",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000017",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C18",
          "name": "更新时间",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "00",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000018",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        },
        {
          "code": "C19",
          "name": "备注",
          "defCode": "USER",
          "dataType": "0",
          "uiType": "00",
          "version": 0,
          "reqLimit": "0",
          "sw": {},
          "mo": {},
          "uid": "F000019",
          "vipLevel": 0,
          "createdBy": "admin",
          "updatedBy": "admin",
          "extMap": {},
          "hasLazy": false
        }
      ],
      "uid": "USER",
      "vipLevel": 0,
      "createdBy": "admin",
      "createdTime": 1638186736000,
      "updatedBy": "admin",
      "updatedTime": 1638186749000,
      "extMap": {},
      "hasLazy": false
    }
  },
  '/api/dataDef/area/search': {
    "code": 1,
    "msg": "success",
    "data": [
      {
        "code": "BASE",
        "name": "基本数据",
      },
      {
        "code": "PERSON",
        "name": "人事管理",
      },
    ]
  },
  '/api/dataDef/structure/search':{
      "code": 1,
      "msg": "success",
      "data": {
        totalRow: 375,
        totalPage: 50,
        list: Mock.mock({
          "array|1-51": [
            {
              "code": "USER@integer(60, 100)",
              "name": "用户管理",
              "type": "0",
              "acode": "base",
              "auditFlag": "0",
              "uid": "USER@integer(1000, 9999)",
              "vipLevel": 0,
              "createdBy": "admin",
              "createdTime": 1638186736000,
              "updatedBy": "admin",
              "updatedTime": 1638186749000,
              "version": 0
            },
          ]
        }).array
      }
  },
};
